
<div class="content">
    <form id="add-form" class="form-horizontal nice-validator n-default n-bootstrap" role="form" data-toggle="validator" method="POST" action="" novalidate="novalidate">

        <div class="form-group">
            <label class="control-label col-xs-12 col-sm-2">产品名称:</label>
            <div class="col-xs-12 col-sm-8 "  style="margin-top:9px;">
                <span>{$name}</span>
            </div>
        </div>
        <div class="form-group">
            <label class="control-label col-xs-12 col-sm-2">层级类别:</label>
            <div class="col-xs-12 col-sm-8"  style="margin-top:9px;">
                <span>{$self_type[$res['pptype']]}</span>
            </div>
        </div>
        <div class="form-group">
            <label class="control-label col-xs-12 col-sm-2">显示标题:</label>
            <div class="col-xs-12 col-sm-8">
                <input  name="id" value="{$res.id}" type="hidden" style="width:400px;">
                <input id="title" class="form-control" name="title" value="{$res.title}" type="text" style="width:400px;">
            </div>
        </div>
        <div class="form-group">
            <label class="control-label col-xs-12 col-sm-2">显示信息:</label>
            <div class="col-xs-12 col-sm-8" >
                <textarea name="info" style="width:400px;">{$res.info}</textarea>
            </div>
        </div>
        <div class="form-group">
            <label class="control-label col-xs-12 col-sm-2">计量单位:</label>
            <div class="col-xs-12 col-sm-8">
                <input id="unit" class="form-control" name="unit" value="{$res.unit}" type="text" style="width:400px;">
            </div>
        </div>
        <div class="form-group">
            <label class="control-label col-xs-12 col-sm-2">状态:</label>
            <div class="col-xs-12 col-sm-8">
                <input  name="status"  value="1" type="radio" {if condition="$res.status eq 1"}checked="checked" {/if}>正常
                <input  name="status"  value="2" type="radio" {if condition="$res.status eq 2"}checked="checked" {/if}>下线
            </div>
        </div>
        <div class="form-group layer-footer">
            <label class="control-label col-xs-12 col-sm-2"></label>
            <div class="col-xs-12 col-sm-8">
                <button type="button" class="btn btn-success btn-embossed" onclick="sub();">确定</button>
                <a href="/admin/product/product_chargeable?pid={$res['pid']}&fid=0" class="btn btn-default btn-embossed">返回</a>
            </div>
        </div>
    </form>
</div>
<script language="javascript" type="text/javascript" src="/assets/My97DatePicker/jquery-1.8.2.js"></script>
<script>
    function sub(){
         var title=$("#ptitle").val();
         if(title==''){
             alert("标题不得为空");
             return;
         }

         $("#add-form").submit();
    }



</script>

